﻿using System.Collections.Generic;

namespace PEProtocol
{
    /// <summary>
    /// 客户端请求数据
    /// </summary>
    public class ReqAcctLogin
    {
        public string Acct { get; set; }
        public string PassWord { get; set; }

        /// <summary>
        /// 当前区服所指向的数据进程ID
        /// </summary>
        public int DataID { get; set; }
    }

    /// <summary>
    /// 服务器通知数据，该登录无返回结构，等待服务器通知
    /// </summary>
    public class NtfRoleDatas
    {
        public List<RoleData> RoleDatas { get; set; }
    }

    /// <summary>
    /// 服务器相应的角色数据
    /// </summary>
    public class RoleData
    {
        public int UID { get; set; }
        public string NickName { get; set; }

        public float PosX { get; set; }
        public float PosY { get; set; }
        public float DirX { get; set; }
        public float DirY { get; set; }

        public ulong LastRid { get; set; } //常驻副本ID
        public ulong LastTID { get; set; } //临时副本ID

        #region 角色成长数值

        /// <summary>
        /// 当前角色基础单位配置ID号
        /// </summary>
        public int UnitID { get; set; }

        /// <summary>
        /// 当前角色等级
        /// </summary>
        public int Level { get; set; }
        
        /// <summary>
        /// 当经验值
        /// </summary>
        public int Exp { get; set; }

        public override string ToString()
        {
            return string.Format("UID:{0}--NickName:{1}--UnitID:{2}--Level:{3}--Exp:{4}",UID,NickName,UnitID,Level,Exp);
        }

        #endregion
    }

    public partial class NetMsg
    {
        public ReqAcctLogin ReqAcctLogin { get; set; }
        public NtfRoleDatas NtfRoleDatas { get; set; }
    }
}